package 常用类库API;
import java.util.*;

public class DogCompare implements Comparator<Dog>
{

	@Override
	public int compare(Dog p1, Dog p2)
	{
		return p1.getAge()-p2.getAge();
	}
	
}
